-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FIX] Contextual errors for this and RegExp declarations in IRC module #8656
Conversation
@@ -44,10 +44,13 @@ class IrcClient { | |||
this.socket.setNoDelay; | |||
this.socket.setEncoding('utf-8'); | |||
this.socket.setKeepAlive(true); | |||
this.connect = this.connect.bind(this); | |||
this.onConnect = this.onConnect.bind(this); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm unless I'm missing something, doesn't this get overwrote by the next line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Derp, I was missing something. 🙈 so never mind!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👌
Not sure if the failing test is because of my changes. Can we run the Travis CI build again? |
@Pharserror we moved to CircleCI, everything passed, I just updated your branch with our develop branch to run the CI again. |
👌 |
@RocketChat/core
Should Close #6902 and #7412
I say Should because I have not been able to deploy this remotely and have only tested the RC fixes locally.
I was getting several "this.someFunction is undefined" errors after enabling the IRC plugin via the admin panel in Chrome 61. I fixed these context errors by binding
this
to the functions that were giving theundefined
message in the constructor.Also, there are several
RegExp
's that were declared such that the functions they were made to trigger were not being triggered. I changed the declarations and now I am seeing messages.